FQDN (Fully Qualified Domain Name) is a hierarchical name that uniquely identifies a device on a network. In the context of Kubernetes, FQDNs are primarily used for Services.
A typical Kubernetes Service FQDN follows this format:
<service-name>.<namespace>.svc.cluster.local
Where:
Consider a Service named "myapp" in the "default" namespace. Its FQDN would be:
myapp.default.svc.cluster.local
You can access a Service using its FQDN from within the Kubernetes cluster. For example, to curl a Service named "myapp":
kubectl exec -n default mypod -- curl myapp.default.svc.cluster.local
Note: The specific method for accessing Services from outside the cluster might vary depending on your network configuration and the type of Service (e.g., NodePort, LoadBalancer, Ingress).
By understanding the structure and purpose of FQDNs in Kubernetes, you can effectively manage and access your Services within the cluster.